package com.eriloan.easyPage.beans;

import java.util.HashMap;
import java.util.Map;

public class ModelAttribute{

	private Map<String,Object> modelAttributes = new HashMap<String,Object>();
	private Map<String,Object> modelSessionAttributes = new HashMap<String,Object>();
	private Map<String,Object> modelCookieAttributes = new HashMap<String,Object>();

	public void addAttribute(String key,Object val){
		modelAttributes.put(key,val);
	}

	public void removeAttribute(String key){
		modelAttributes.remove(key);
	}

	public void clearAttribute(){
		modelAttributes.clear();
	}

	public void addSessionAttribute(String key,Object val){
		modelSessionAttributes.put(key,val);
	}

	public void removeSessionAttribute(String key){
		modelSessionAttributes.remove(key);
	}

	public void clearSessionAttribute(){
		modelSessionAttributes.clear();
	}

	public void addCookieAttribute(String key,Object val){
		modelCookieAttributes.put(key,val);
	}

	public void removeCookieAttribute(String key){
		modelCookieAttributes.remove(key);
	}

	public void clearCookieAttribute(){
		modelCookieAttributes.clear();
	}

	public Map<String,Object> getModelAttributes(){
		return modelAttributes;
	}

	public Map<String,Object> getModelSessionAttributes(){
		return modelSessionAttributes;
	}

	public Map<String,Object> getModelCookieAttributes(){
		return modelCookieAttributes;
	}
}
